package com.ssyt.yt1.day9.abstractdemo.shape;

public class Square extends Shape {

	private double length;

	public Square() {
		super();
	}

	public Square(double length) {
		super();
		this.length = length;
	}

	public double getLength() {
		return length;
	}

	public void setLength(double length) {
		this.length = length;
	}

	@Override
	public double getPerimeter() {
		return 4 * length;
	}

	@Override
	public double getArea() {
		return Math.pow(length, 2);
	}
}
